package com.migration.model.olddb;

import jakarta.persistence.*;
import lombok.Data;
import java.time.LocalDateTime;
import java.io.Serializable;

/**
 * 报警上报信息表 实体类
 * 表名：ra_alarm_reported
 * 自动生成的实体类
 */
@Data
@Entity
@Table(name = "ra_alarm_reported")
public class RaAlarmReported implements Serializable {

    private static final long serialVersionUID = 1L;
    
    /**
     * 主键
     * 主键
     */
    @Id
    @Column(name = "id", nullable = false)
    private Long id;
    
    /**
     * 报警详情编码
     */
    @Column(name = "alarm_code", length = 32)
    private String alarmCode;
    
    /**
     * 上报类型（1、报警 2、影响分析）
     * 默认值: 1
     */
    @Column(name = "appear_type", nullable = false)
    private Byte appearType;
    
    /**
     * 报警分组记录主键
     */
    @Column(name = "alarm_record_group_id")
    private Long alarmRecordGroupId;
    
    /**
     * 报警信号
     */
    @Column(name = "alarm_bit_no", length = 128)
    private String alarmBitNo;
    
    /**
     * 报警所在设备名称
     */
    @Column(name = "alarm_node", length = 64)
    private String alarmNode;
    
    /**
     * 设备所在偏离名称
     */
    @Column(name = "alarm_deviate", length = 128)
    private String alarmDeviate;
    
    /**
     * 报警影响
     * 默认值: 1
     */
    @Column(name = "appear_inf_id")
    private Long appearInfId;
    
    /**
     * 报警影响描述
     */
    @Column(name = "appear_inf_desc", length = 256)
    private String appearInfDesc;
    
    /**
     * 防护措施
     */
    @Column(name = "defend_desc", length = 256)
    private String defendDesc;
    
    /**
     * 防护措施位号
     */
    @Column(name = "defend_bit_no", length = 128)
    private String defendBitNo;
    
    /**
     * 上报说明
     */
    @Column(name = "appear_explain", length = 65535)
    private String appearExplain;
    
    /**
     * 租户主键
     */
    @Column(name = "tenant_id")
    private Integer tenantId;
    
    /**
     * 状态
     * 默认值: 0
     */
    @Column(name = "status")
    private Byte status;
    
    /**
     * 是否删除（0、否1、是）
     * 默认值: 0
     */
    @Column(name = "is_del", nullable = false)
    private Byte isDel;
    
    /**
     * 创建时间
     * 默认值: CURRENT_TIMESTAMP
     */
    @Column(name = "create_time", nullable = false)
    private java.time.LocalDateTime createTime;
    
    /**
     * 创建者
     */
    @Column(name = "create_by", length = 64)
    private String createBy;
    
    /**
     * 更新时间
     * 默认值: CURRENT_TIMESTAMP
     */
    @Column(name = "update_time", nullable = false)
    private java.time.LocalDateTime updateTime;
    
    /**
     * 更新者
     */
    @Column(name = "update_by", length = 64)
    private String updateBy;
    
    @Override
    public String toString() {
        return "RaAlarmReported{" +
            "id=" + id +
            ", alarmCode=" + alarmCode +
            ", appearType=" + appearType +
            ", alarmRecordGroupId=" + alarmRecordGroupId +
            ", alarmBitNo=" + alarmBitNo +
            ", alarmNode=" + alarmNode +
            ", alarmDeviate=" + alarmDeviate +
            ", appearInfId=" + appearInfId +
            ", appearInfDesc=" + appearInfDesc +
            ", defendDesc=" + defendDesc +
            ", defendBitNo=" + defendBitNo +
            ", appearExplain=" + appearExplain +
            ", tenantId=" + tenantId +
            ", status=" + status +
            ", isDel=" + isDel +
            ", createTime=" + createTime +
            ", createBy=" + createBy +
            ", updateTime=" + updateTime +
            ", updateBy=" + updateBy +
        '}';
    }
} 